package com.sens.mybank.utils;

import com.sens.tables.MybankOrder;
import com.sens.vo.MybankOrderVo;

public class OrderUtil {
    public static MybankOrder createMybankOrder(MybankOrderVo mybankOrderVo) {
        if (mybankOrderVo == null) return null;
        MybankOrder mybankOrder = new MybankOrder();
        mybankOrder.setTime(mybankOrderVo.getTime());
        mybankOrder.setOrderId(mybankOrderVo.getOrderId());
        mybankOrder.setAmount(mybankOrderVo.getAmount());

        mybankOrder.setCurrencyCode(mybankOrderVo.getCurrencyCode());
        mybankOrder.setTradeRemark(mybankOrderVo.getTradeRemark());
        mybankOrder.setOwnerName(mybankOrderVo.getOwnerName());
        mybankOrder.setOwnerCardNo(mybankOrderVo.getOwnerCardNo());
        mybankOrder.setTradeNo(mybankOrderVo.getTradeNo());
        mybankOrder.setTradeName(mybankOrderVo.getTradeName());
        mybankOrder.setOppositeCardNo(mybankOrderVo.getOppositeCardNo());
        mybankOrder.setOppositeName(mybankOrderVo.getOppositeName());
        return mybankOrder;
    }

}
